package com.terracloud.server.service.entitiy.device.group;

import com.terracloud.server.common.data.DeviceGroup;
import com.terracloud.server.common.data.id.DeviceGroupId;
import com.terracloud.server.common.data.id.TenantId;
import com.terracloud.server.common.data.page.PageData;
import com.terracloud.server.common.data.page.PageLink;
import com.terracloud.server.service.security.model.SecurityUser;
import com.terracloud.server.vo.DeviceGroupRelationUpdateVo;

/**
 *
 * @author chenhainan
 * @since 2025/10/11
 */
public interface TbDeviceGroupService {

    DeviceGroup saveDeviceGroup(DeviceGroup deviceGroup, SecurityUser currentUser);

    DeviceGroup findDeviceGroupById(TenantId tenantId, DeviceGroupId id);

    DeviceGroup findDeviceGroupInfoById(TenantId tenantId, DeviceGroupId id);

    void delete(DeviceGroup deviceGroup, SecurityUser currentUser);

    PageData<DeviceGroup> findDeviceGroups(TenantId tenantId, PageLink pageLink);

    void addDeviceToGroup(SecurityUser currentUser, DeviceGroupRelationUpdateVo deviceGroupRelationUpdateVo);

    void removeDeviceFromGroup(SecurityUser currentUser, DeviceGroupRelationUpdateVo deviceGroupRelationUpdateVo);
}
